package com.xqboss.apps.domain.user;

import java.math.BigDecimal;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.xqboss.apps.domain.BaseTable;
import com.xqboss.apps.enums.user.UserWalletEnum;
import com.xqboss.common.annotation.Excel;
import com.xqboss.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.persistence.Id;

/**
 * 用户钱包对象 sys_user_wallet
 *
 * @author xqboss
 * @date 2023-08-14
 */
@Data
public class SysUserWallet extends BaseTable {
    private static final long serialVersionUID = 1L;

    /**
     * 钱包ID
     */
    @TableId
    @Id
    private Long id;

    /**
     * 用户ID
     */
    @Excel(name = "用户ID")
    @ApiModelProperty("用户ID")
    private Long userId;

    /**
     * 钱包类型（1：现金钱包  2：热豆钱包）
     */
    @Excel(name = "钱包类型", readConverterExp = "1=：现金钱包,2=：热豆钱包,3=：力豆钱包")
    @ApiModelProperty("钱包类型")
    private UserWalletEnum type;

    /**
     * 余额
     */
    @Excel(name = "余额")
    @ApiModelProperty("钱包余额")
    private BigDecimal amount;

    /**
     * 冻结金额
     */
    @Excel(name = "冻结金额")
    @ApiModelProperty("钱包冻结金额")
    private BigDecimal freeze;

    /**
     * 提现中金额
     */
    @Excel(name = "提现中金额")
    @ApiModelProperty("钱包提现冻结金额")
    private BigDecimal withdraw;

    @ApiModelProperty("累计充值")
    private BigDecimal totalRecharge;

    @ApiModelProperty("累计消费")
    @JsonIgnore
    private BigDecimal totalExpend;

    @ApiModelProperty("累计提现")
    @JsonIgnore
    private BigDecimal totalWithdraw;

    @ApiModelProperty("免费提现额度")
    @JsonIgnore
    private BigDecimal freeWithdrawAmount;
}
